home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Video Toaster 4.2
/
Video Toaster v4.2.iso
/
programs
/
documentation
/
misc
/
toastnserial.doc
< prev
next >
Wrap
Text File
|
1993-12-13
|
3KB
|
58 lines
ToastNSerial -- Serial control of the Video Toaster
Arnie Cachelin © 1993 NewTek Inc.
This release of the Video Toaster provides two methods for remote control
of the Toaster using the serial port, an arexx script called
ToasterSerialHost.rexx, and ToastNSerial. ToastNSerial is a small program
which waits for external commands coming in on the Amiga's RS-232 serial port,
and passes whatever it gets to the Toaster's Switcher in a form it can
understand. The program will also return appropriate Switcher status or error
information through the serial port.
Configuration
ToastNSerial can be launched from the AmigaDOS Command Shell (CLI), or
from the Workbench graphical interface. It will use the current system serial
port preferences (set with the Prefs/Serial program), unless other settings
are given at launch either by command line arguments for CLI launches, or
by the ToolTypes array contained in the ToastNSerial icon in the case of a
Workbench launch. The [optional] command line parameters will
be displayed if the program is run with the argument "-?". They are:
-b<baud> -s<settings> -d<device> -u<unit>. Supported icon ToolTypes are
similar, use: BAUD=<baud>, SETTINGS=<settings>, DEVICE=<device>,
UNIT=<unit>. Baud should be a communication rate between 300 and 38400,
settings consist of data bits, parity, and stop bits in a format like "8N1"
or "7E1". The device and unit settings are only useful if you have multiple
serial port hardware installed. These parameters currently default to the
Amiga's internal serial port (DEVICE=serial.port UNIT=0).
Program Input
ToastNSerial expects to receive valid ARexx commands for the Video
Toaster, which are documented in the file SwitcherARexx.doc.
The serial input to the Toaster should consist of one Toaster command
per line. An ASCII 13 (CR) or 10 will terminate a line. The call to the
Switcher() function is not necessary, so if the command in an ARexx script
looked like "Switcher(AUTO)" you should send the line "AUTO". Multiple
arguments are separated with commas (i.e. ARexx command
"Switcher(FMSV,73,Art)" becomes line "FMSV,73,Art". Note that all commands
must be all UPPERCASE or they will fail. To shut down ToastNSerial, send it
the command "EXIT".
Program output
ToastNSerial will write to the serial port after each operation has
completed. To avoid losing commands, it is advisable to await the return
before sending another line. If the command was successful, it will return
either an "OK", or the result of the command. If the command fails it
returns "ERROR 10", if the Toaster isn't running, it says "No Toaster!".
The text returned by this program does not have the carriage return at the
end which it requires on its input. When the program is launched, it will
send "READY!" out to the serial port. If you send the command "EXIT", the
program will remove itself after sending the string "BYE BYE" to the serial
port. This is the only way to exit ToastNSerial. The program will also
print out the valid commands it sends to the Toaster. These will appear in
the command shell whence the program was launched. This output can be
redirected into a file which will have the guts of an ARexx script to
duplicate the entire remote Toaster session. Just combine it with the
startup code in the ToasterSkeleton.rexx. This is a useful debugging
method with great potential.